<?php

include "connect.php";

if( isset($_POST['productID'])) {} else { header('Location: index.php');}

?>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title><?php echo "#".$productID." - ".$productName." Order Details" ?></title>

<meta name="description" content="View our large range of horse saddles online | We have saddles for most disciplines including General Purpose | Dressage | Eventing | Working | Hunter and VSD. Buy or sell saddles online." />

<link href="css/main.css" rel="stylesheet" type="text/css" />
<style type="text/css">
body {
	background-image: url(images/background.jpg);
	background-repeat: repeat-x;
	background-position: center top;
	background-attachment: fixed;
	margin: 0px;
	padding: 0px;
}
</style>
<link href="css/yourDetails.css" rel="stylesheet" type="text/css" />
</head>

<?php include "header.php"; ?>

<?php  
$productID=$_POST['productID'];
$productName=$_POST['productName'];
$productCost=$_POST['productCost'];
?>

<div id="content">

<h2>Fill In Your Details Below To Purchase Your Saddle By Cash Payment</h2>

<h3 class="header">Product Details</h3>

<img src="images/saddles/<?php echo $productID ?>_1.jpg" width="250" height="200" />

<div id="productDetails">
<p>
<b>Product ID:</b> <?php echo $productID ?><br /><br />
<b>Product Name:</b> <?php echo $productName ?><br /><br />
<b>Product Cost:</b> <?php echo "£".$productCost ?><br /><br />

</p>
</div>

<h3 class="header">Your Details</h3>

<form action="sendBuyCash.php" method="post" name="customerDetails">

<select class="smallField" name="title">
  <option value="Mr">Mr</option>
  <option value="Mrs">Mrs</option>
  <option value="Miss">Miss</option>
  <option value="Ms">Ms</option>
  <option value="Other">Other</option>
</select>

<input name="name" type="text" class="mediumField" onfocus="if(this.value == this.defaultValue) this.value = ''" onblur="if(this.value == '') this.value =this.defaultValue" value="Your Name" />

<input name="email" type="text" class="mediumField" onfocus="if(this.value == this.defaultValue) this.value = ''" onblur="if(this.value == '') this.value =this.defaultValue" value="Email Address" />

<input name="contactNumber" type="text" class="mediumField" onfocus="if(this.value == this.defaultValue) this.value = ''" onblur="if(this.value == '') this.value =this.defaultValue" value="Contact Number" />

<h3 class="header">Address Details</h3>

<input name="postcode" type="text" class="smallField" onfocus="if(this.value == this.defaultValue) this.value = ''" onblur="if(this.value == '') this.value =this.defaultValue" value="Postcode" />

<input name="addressLine1" type="text" class="mediumField" onfocus="if(this.value == this.defaultValue) this.value = ''" onblur="if(this.value == '') this.value =this.defaultValue" value="Address Line 1" />

<input name="addressLine2" type="text" class="mediumField" onfocus="if(this.value == this.defaultValue) this.value = ''" onblur="if(this.value == '') this.value =this.defaultValue" value="Address Line 2" />

<br />
<br />

<input name="town" type="text" class="mediumField" onfocus="if(this.value == this.defaultValue) this.value = ''" onblur="if(this.value == '') this.value =this.defaultValue" value="Town" />

<input type="hidden" value="<?php echo $productID ?>" name="productID" />
<input type="hidden" value="<?php echo $productName ?>" name="productName" />
<input type="hidden" value="<?php echo $productCost ?>" name="productCost" />


<input id="sendButton" name="sendButton" type="submit" value="Place Order" />

</form>
</div>
<!--Content #End-->

<?php include"footer.php" ?>


</body>
</html>